import {defineConfig} from 'vite'
import vue from '@vitejs/plugin-vue'
import {resolve} from 'path';

// https://vitejs.dev/config/

const pathResolve = (dir) => {
    return resolve(__dirname, '.', dir);
};

const alias = {
    '/@': pathResolve('./src/'),
    '@views': pathResolve('./src/views'),
};

export default defineConfig({
    plugins: [vue()],
    resolve: {alias},
    server: {
        host: '0.0.0.0',
        port: 8080,
        // 是否开启 https
        https: false,
    },
})
